<template>
	<view v-if="load" :style="{
		backgroundColor:info.bg_color,
		paddingBottom:'30upx'
	}">
		<uni-head title="产品详情" ></uni-head>
		<image :src="info.detail_img" mode="widthFix" class="bx-banner" ></image>
		<view class="bx-card" >
			<view class="bx-card-title" >
				<text>{{info.name}}</text>
				<text class="bx-card-title-red" v-if="info.type_name">·{{info.type_name}}</text>
			</view>
			<image src="https://jy-yyzj.oss-cn-shanghai.aliyuncs.com/jdbx/h5/bx-d-1.png" mode="widthFix" class="bx-card-title-line" ></image>
			<view class="bx-card-table bx-card-table-t" >
				<view class="bx-card-table-th bx-card-table-th-first">项目</view>
				<view class="bx-card-table-th bx-card-table-th-blue" v-for="(item,index) in info.fananlist" :key="index">方案{{index+1}}</view>
				</view>
				<view class="bx-card-table bx-card-table-t">
				  <view class="bx-card-table-th bx-card-table-th-red">
				    <view>高空保费</view>
				    <view>（人/年）</view>
				  </view>
				  <view class="bx-card-table-th bx-card-table-th-red" v-for="(item,index) in info.fananlist" :key="index">{{info.fanan[item].price}}元</view>
				</view>
				<view class="bx-card-table">
				  <view class="bx-card-table-head">死亡/伤残</view>
						<!-- <view class="bx-card-table-td bx-card-table-td-nb">150万/人</view> -->
				  <view class="bx-card-table-td" v-for="(item,index) in info.fananlist"  :key="index">{{item}}/人</view>
				</view>
			<view class="bx-card-table" >
				<view class="bx-card-table-head">医疗费用</view>
				<view class="bx-card-table-td">
					<view>20万/人 </view>
					<view><text class="bx-card-table-color-red">100%赔付</text>（含自费药）</view>
				</view>
			</view>
			<view class="bx-card-table" >
				<view class="bx-card-table-head">误工费</view>
				<view class="bx-card-table-td bx-card-table-td-nb bx-card-table-center">
					<view>100元/天，以医生证明的建议休息天数（含实际 住院天数）计算，<text class="bx-card-table-color-red">最长180天</text> </view>
				</view>
			</view>
			<view class="bx-card-table" >
				<view class="bx-card-table-head">住院津贴</view>
				<view class="bx-card-table-td bx-card-table-td-nb bx-card-table-center">
					<view>100元/天 </view>
				</view>
			</view>
			<view class="bx-card-table" >
				<view class="bx-card-table-head">法律费用</view>
				<view class="bx-card-table-td bx-card-table-td-nb">10万/年/服务商</view>
			</view>
			<!-- <view class="bx-card-table" >
				<view class="bx-card-table-head" style="text-align: center;">免费扩展24小时意外</view>
				<view class="bx-card-table-td bx-card-table-left bx-card-table-td-nb">扩展承保保险期内雇员因发生个人意外事故而导致的死亡、伤残赔偿(接私活除外)</view>
			</view> -->
			<view class="bx-card-table" >
				<view class="bx-card-table-head">赔偿标准</view>
				<view class="bx-card-table-td bx-card-table-left bx-card-table-td-nb">
					<view>1、死亡/伤残：0免赔。</view>
					<view>2、医疗费用：0免赔，包含合理且必要的医保用药及自费药100%赔付。</view>
					<view>3、误工费：免费0天。误工天数的计算，根据医嘱建议休息天数，并结合实际伤情综合核定的最小时间，每人累计赔偿不超过180天。</view>
					<view>4、法律费用：无免赔</view>
					<view>5、第三者责任：每次事故赔偿限额，每人最高不超过 50 万。本保险适用伤残赔偿限额比例为一级伤残100%、二级伤残90%、三级伤残80%、四级伤残70%、五级伤残60%、六级伤残50%、七级伤残40%、八级伤残20%、九级伤残10%、十级伤残5%</view>
				</view>
			</view>
			<view class="bx-card-table" >
				<view class="bx-card-table-head" style="text-align: center;">24小时意外险</view>
				<view class="bx-card-table-td bx-card-table-left bx-card-table-td-nb">
					扩展被保人员全天24小时因意外份害导致的死亡、伤残事故，保险人以保险单明细表及特约中列明的限额为限承担赔偿责任，其中非工作意外的赔偿限额为主险赔偿限额的50%。
				</view>
			</view>
			<view class="bx-third-t">
				<text>附加第三者保障</text>
				<text class="bx-third-t-sm">（可选择投保）</text>
			</view>
			<view class="bx-third-center" >
				<view class="bx-card-table-head bx-card-table-head-nb">现场第三者保额</view>
				<view class="bx-third-center-right">
					<view class="bx-third-center-right-itme bx-third-center-right-center">
						<view>全年累计限额50万</view>
						<view>其中每人每次事故赔偿限额20万，</view>
						<view>每次财产损失限额10万</view>
					</view>
					<view class="bx-third-center-right-itme bx-third-center-right-bottom">
						<view>1、死亡/伤残：<text class="bx-card-table-color-red">无免赔</text></view>
						<view>2、人伤：无免赔，<text class="bx-card-table-color-red">100%赔付</text></view>
						<view>3、财产损失：<text class="bx-card-table-color-red">每次事故绝对免赔额1000元或损失金额的10% ，两者以高者为准。</text></view>
					</view>
				</view>
			</view>
			<view class="bx-card-table" >
				<view class="bx-card-table-head">新机完工保费</view>
				<view class="bx-card-table-td bx-card-table-td-nb bx-card-table-color-red">170元/人/年</view>
			</view>
			<!-- <image src="https://jy-yyzj.oss-cn-shanghai.aliyuncs.com/jdbx/h5/f1.png" mode="widthFix" class="bx-card-img"></image>
			<image src="https://jy-yyzj.oss-cn-shanghai.aliyuncs.com/jdbx/h5/f2.png" mode="widthFix" class="bx-card-img"></image> -->
		</view>
		<view class="bx-lines" ></view>
		<view class="bx-footer" >
			<view class="bx-footer-left" @tap="toHome()" >
				<image src="https://jy-yyzj.oss-cn-shanghai.aliyuncs.com/jdbx/h5/tohome.png" class="bx-footer-icon" mode="widthFix"></image>
				<view class="bx-footer-left-txt">返回首页</view>
			</view>
			<view class="bx-footer-right" @tap="toForm()" >立即投保</view>
		</view>
	</view>
</template>

<script>
	import uniHead from '@/components/uni-dead/head.vue';
	
	export default{
		components:{ uniHead },
		data(){
			return {
				info:{},
				load : false,
				
			}
		},
		onLoad() {
			this.getData();
		},
		methods:{
			toForm(){
				uni.showModal({
				    title: '重要提示',
				    content: '尊敬的客户，您即将进入太平洋保险的产品投保流程。根据银监会[2020]26号的监管规定，为了维护您的权益，您在投保过程中的完整操作轨迹将被记录，请您仔细阅读条款、责任免除、特别约定等内容。',
					showCancel : false,
				    success:  (res) => {
				        if (res.confirm) {
				            if(this.info.is_login == 0) {
				            	this.toast('请先登录');
				            	setTimeout(()=>{
				            		uni.reLaunch({
				            			url:'/pages/login/login'
				            		})
				            	},1000);
				            	return;
				            }
				            uni.navigateTo({
				            	url:'/pages/bx/form?id='+this.info.id
				            })
				        }
				    }
				});
				
			},
			getData(){
				uni.showLoading({
					title:'加载中'
				})
				this.ajax('index/detail',{
					data:{
						id : 2
					},
					success:(res) => {
						this.info = res.msg;
						uni.hideLoading();
						this.load = true;
					}
				});
			},
			toHome(){
				uni.switchTab({
					url:'/pages/index/index'
				})
			}
		}
	}
</script>

<style>
	@import url("@/static/css/box/index.css");
</style>
